from d3blocks import D3Blocks

d3 = D3Blocks()
#
# Import example
df = d3.import_example('energy') # 'bigbang', 'stormofswords'
#
# Create network using default
d3.d3graph(df, filepath='d3graph.html')
#
# Change scaler
d3.d3graph(df, scaler='minmax')
#
# Change node properties
d3.D3graph.set_node_properties(color=None)
d3.D3graph.node_properties['Solar']['size']=30
d3.D3graph.node_properties['Solar']['color']='#FF0000'
d3.D3graph.node_properties['Solar']['edge_color']='#000000'
d3.D3graph.node_properties['Solar']['edge_size']=5
d3.D3graph.show()
#
# Change edge properties
d3.D3graph.set_edge_properties(directed=True, marker_end='arrow')
d3.D3graph.show()
#
# Node properties
d3.D3graph.node_properties
#
# Node properties
d3.D3graph.edge_properties
#
# After making changes, show the graph again using show()
d3.D3graph.show()